<!DOCTYPE html>
<html lang="zh">
<head>
  <meta charset="utf-8"/>
</head>
<body>
<!--
 这是同域下的callback页面，本页面在iframe内，所以只要通过window.parent就能操作父窗口的元素
-->
<script type="text/javascript">
  var query = {};
  var array = window.location.search.split('?');
  var urlParams = array[1];
  urlParams = urlParams.split("&");

  for (var i = 0; i < urlParams.length; i++) {
    var param = urlParams[i].split("=");
    query[param[0]] = param[1];
  }

  var success = parseInt(query['success']);
  var message = decodeURI(query['message']);
  var dataUrl = query['url'] + '?' + array[2];

  document.body.innerText = '{"success":' + success + ',"message":"' + message + '","url":"' + dataUrl + '"}';
</script>
</body>
</html>
